<template>
  <div>
    我是comp2组件
    <p>我的值是：{{ value }}</p>
    <button @click="value++">+</button>
  </div>
</template>

<script>
export default {
  name: 'comp2'
}
</script>
<script setup>
import { ref } from 'vue'
const value = ref(0)
</script>

<style scoped>

</style>